<form id="add-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Pid')}:</label>
        <div class="col-xs-12 col-sm-8">
            <select id="c-pid" data-rule="required" class="form-control selectpicker btn-select" name="row[pid]">
                <option data-type="text" value="{$addVehile ? $addVehile.id : 0}" >{$addVehile ? $addVehile.mergename : '顶级分类'}
                    <dd style="background:#00FFFF;">
                        {switch $level}
                        {case 1} -- 厂牌 {/case}
                        {case 2} -- 车型 {/case}
                        {case 3} -- 年份 {/case}
                        {case 4} -- 排量 {/case}
                        {case 5} -- 款型 {/case}
                        {/switch}
                    </dd>
                </option>
            </select>
        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Mergename')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-mergename" data-rule="required" class="form-control" name="row[mergename]" type="text">
        </div>
    </div>
    <div class="form-group" id="c-logos" style = <?php if($level == 0 || $level == 4) {echo "display:block";} else {echo "display:none";}  ?> >
    <label class="control-label col-xs-12 col-sm-2">{:__('Logo')}:</label>
    <div class="col-xs-12 col-sm-8">
        <div class="input-group">
            <input id="c-logo" class="form-control" size="50" name="row[logo]" type="text">
            <div class="input-group-addon no-border no-padding">
                <span><button type="button" id="faupload-logo" class="btn btn-danger faupload" data-input-id="c-logo" data-mimetype="image/gif,image/jpeg,image/png,image/jpg,image/bmp,image/webp" data-multiple="false" data-preview-id="p-logo"><i class="fa fa-upload"></i> {:__('Upload')}</button></span>
                <span><button type="button" id="fachoose-logo" class="btn btn-primary fachoose" data-input-id="c-logo" data-mimetype="image/*" data-multiple="false"><i class="fa fa-list"></i> {:__('Choose')}</button></span>
            </div>
            <span class="msg-box n-right" for="c-logo"></span>
        </div>
        <ul class="row list-inline faupload-preview" id="p-logo"></ul>
    </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Flag')}:</label>
        <div class="col-xs-12 col-sm-8">
            <div class="radio">

                {foreach name="flastList" item="vo"}
                <label for="row[flag]-{$key}"><input id="row[flag]-{$key}" name="row[flag]" type="radio" value="{$key}" {in name="key" value="nohot"}checked{/in} /> {$vo}</label>
                {/foreach}

            </div>
        </div>
    </div>

    <div class="form-group layer-footer">
        <label class="control-label col-xs-12 col-sm-2"></label>
        <div class="col-xs-12 col-sm-8">
            <button type="submit" class="btn btn-primary btn-embossed disabled">{:__('OK')}</button>
            <button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
        </div>
    </div>
</form>
